
\begin{tikzpicture}
  \coordinate[label=below:$A$] (A) at (4,0);
  \coordinate[label=above:$B$] (B) at (0,4);
  \coordinate[label=below:$C$] (C) at (-1,0);
  \coordinate[label=below left:$P$] (P) at ($ (B)!(A)!(C) $);
  \coordinate[label=below:$Q$] (Q) at ($ (C)!(B)!(A) $);
  \coordinate[label=above right:$R$] (R) at ($ (A)!(C)!(B) $);
  \pic[mark angle={cyan}{2mm}{1}] {right angle=A--P--B};
  \pic[mark angle={cyan}{2mm}{1}] {right angle=A--Q--B};
  \pic[mark angle={cyan}{2mm}{1}] {right angle=C--R--A};
  \pic[mark angle={red}{3mm}{1}] {angle=A--P--R};
  \pic[mark angle={red}{3mm}{1}] {angle=Q--P--A};
  \pic[mark angle={red}{3mm}{1}] {angle=Q--B--A};
  \fill[opafill=cyan] (P) -- (Q) -- (R) -- cycle;
  \path[draw, name path=AP] (A) -- (P);
  \path[draw, name path=BQ] (B) -- (Q);
  \path[draw, name intersections={of=AP and BQ}]
    coordinate[label=left:$O$] (O) at (intersection-1);
  \draw (A) -- (B) -- (C) -- cycle (C) -- (R)
    (P) -- (Q) (Q) -- (R) (R) -- (P);
  \node[draw=teal, densely dashed, circle through=(P)]
    at ($ (O)!.5!(B) $) {};
  \node[draw=teal, densely dashed, circle through=(P)]
    at ($ (A)!.5!(B) $) {};
\end{tikzpicture}
